import request from '@/utils/request'

// 添加机构
export function organizationApiadd(data) {
    return request({
        url: '/organizationApi/add',
        method: 'post',
        data
    })
}

// 修改机构
export function organizationApiedit(data) {
    return request({
        url: '/organizationApi/edit',
        method: 'post',
        data
    })
}
// 删除机构
export function organizationApidelete(data) {
    return request({
        url: '/organizationApi/delete',
        method: 'post',
        data
    })
}

// 查询列表
export function organizationApiqueryAll(data) {
    return request({
        url: '/organizationApi/queryAll',
        method: 'post',
        data
    })
}
// 查询详情
export function organizationApiqueryOne(query) {
    return request({
        url: '/organizationApi/queryOne',
        method: 'GET',
        params:query
    })
}


// 获取可以审核的机构
export function getApprovalAuthByOrgId(query) {
    return request({
        url: '/contentApi/getApprovalAuthByOrgId',
        method: 'GET',
        params:query
    })
}


export function saveApprovalAuthByOrgId(data) {
    return request({
        url: '/contentApi/saveApprovalAuthByOrgId',
        method: 'post',
        data
    })
}

export function queryCascadeUser(query) {
    return request({
        url: '/organizationApi/queryCascadeUser', //?userId='+userId
        method: 'GET',
        params:query
    })
}



